package com.skit.common.utils;

/**
 * @author shuike <a href="mailto:shuike007@gmail.com">Contact me.</a>
 * @version 1.0
 * @since 2020/5/23
 */
public class TextUtils {
    public static boolean isNullOrEmpty(String s) {
        return s == null || s.isEmpty();
    }

    public static boolean isNullOrEmpty(String... s) {
        for (String s1 : s) {
            if (null == s1 || s1.isEmpty()) return true;
        }
        return false;
    }

    public static boolean isNumber(String s) {
        try {
            Integer.parseInt(s);
        } catch (Exception e) {
            return false;
        }
        return true;
    }

    public static String numTransferChinese(int num) {
        String[] strings = new String[]{"零", "一", "二", "三", "四", "五", "六", "七", "八", "九"};
        return strings[num];
    }
}
